<?php
@session_start();

if (!isset($_SESSION['languaje'])){
	$_SESSION['languaje']='es';
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="es">
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
		<meta name="viewport" content="width=device-width, initial-scale=1.0">
		<meta name="description" content="Atenticaci&oacute;n | Panel de Control | First Class Apartments Cordoba Argentina">
		<meta name="author" content="Pulce Web Solutions - www.pulce.com.ar">
		<!--Para que las páginas se muestren correctamente y el zoom funcione bien en los dispositivos móviles-->
		<meta name="viewport" content="width=device-width, initial-scale=1.0">
		<meta name="keywords" content="Departamento,Alquiler,Temporal,Cordoba,Capital,Argentina,First Class Apartments,Alojamiento,Turismo,Panel,Control,LogIn,Auenticaci&oacute;n">

		<title>Autenticaci&oacute;n | Panel de Control | Alquiler de Apartamentos en C&oacute;rdoba Argentina | First Class Apartments C&oacute;rdoba Argentina | Apartamentos en C&oacute;rdoba Argentina</title>

		<?php
			include_once('../links.php');
		?>
		<!--FUNCTIONS-->
		<script src="../js/functions.js"></script>
		<!--JQUERY-->
		<script src="http://code.jquery.com/jquery-2.1.0.js"></script>
		<!--MD5-->
		<script src="../js/md5.js"></script>

		<script src="../js/jquery.loadmodal.js"></script>

		<script type="text/javascript">	
			/*$('#form-login').on('change',function(e){
				if (hasMsg('div-msg'))
					$('#div-msg').fadeOut();	
			});*/

			$(document).ready(function(){				
				$('#login').on('click',function(e){
					/*if (hasMsg('div-msg'));
						$('#div-msg').fadeOut();*/
					var pwd = $('#password').val();
					pwd=encriptar(pwd);
					g("ajax.php?"+a('verificarUsuario')+v('usuario')+c('password',pwd),'div-result','div-msg','div-img',false);
				});

				$("#password").keypress(function(e){
					if (e.which == 13)
						$("#login").click();
				});
				$( "#usuario" ).focus();
			});
			
		</script>
	</head>
	<body cz-shortcut-listen="true" class="fondo-oscuro">
		<div class="container">
			<div id="form-login" class="row" style="margin-top:10%;">
				<div class="col-xs-3 col-xs-offset-1">
					<!--<div class="box-logo" style="margin:0px;">-->
						<img src="../img/logo_orig.png" class="img-logo"/>
					<!--</div>-->
				</div>
			    <div id="form" class="col-xs-5">
				    <div class="row">
				    	<div class="col-xs-offset-3">
				    		<img src="../img/symbol/login_title.png" style="display:inline;"/>
				    		<h2 class="form-signin-heading" style="text-align:center;display:inline;">Ingreso a Panel de Control</h2>
				    	</div>
				    </div>
				    <div class="row margin-top-1em">
						<label for="usuario" class="col-xs-3 control-label label-custom">Usuario</label>
						<div class="col-xs-9">
							<input type="text" class="form-control" id="usuario" placeholder="" tabindex="1">
						</div>
					</div>
					<div class="row margin-top-1em">
						<label for="password" class="col-xs-3 control-label label-custom">Contraseña</label>
						<div class="col-xs-9">
							<input type="password" class="form-control" id="password" placeholder="" tabindex="1">
						</div>
			        </div>
			        <div class="row margin-top-1em" text-align="center">
			        	<div id="div-img" class="col-xs-offset-3"></div>
			        </div>
			        <div class="row margin-top-1em">
			        	<div class="col-xs-offset-3" style="text-align:center;">
			        		<button id="login" class="btn btn-lg btn-success" style="width:90%">Ingresar</button>
			        	</div>
			        </div>
			        <div id="div-msg" class="margin-top-1em" type="hidden">
					</div>
			    </div>
			</div>
	      	<div id="div-result">
			</div>
	    </div>
	</body>
</html>